package com.winit.attachment.model;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;

@Entity
@Table(name = "matrix_attachment")
@DynamicUpdate
@DynamicInsert
public class Attachment implements Serializable {
    @Id
    @Column(name = "attachment_id")
    private String attachmentId;
    @Column(name = "attachment_name")
    private String attachmentName;
    //附件访问地址
    @JsonIgnore
    @Column(name = "attachment_url")
    private String attachmentUrl;
    @JsonIgnore
    @Column(name = "attachment_owner_id")
    private String attachmentOwnerId;
    //文件系统的保存路径
    @JsonIgnore
    @Column(name = "attachment_path")
    private String attachmentPath;
    //'是否删除 0 删除 1 未删除',
    @JsonIgnore
    @Column(name = "attachment_is_del")
    private String attachmentIsDel;

    public String getAttachmentId() {
        return attachmentId;
    }

    public void setAttachmentId(String attachmentId) {
        this.attachmentId = attachmentId;
    }

    public String getAttachmentName() {
        return attachmentName;
    }

    public void setAttachmentName(String attachmentName) {
        this.attachmentName = attachmentName;
    }

    public String getAttachmentUrl() {
        return attachmentUrl;
    }

    public void setAttachmentUrl(String attachmentUrl) {
        this.attachmentUrl = attachmentUrl;
    }

    public String getAttachmentOwnerId() {
        return attachmentOwnerId;
    }

    public void setAttachmentOwnerId(String attachmentOwnerId) {
        this.attachmentOwnerId = attachmentOwnerId;
    }

    public String getAttachmentPath() {
        return attachmentPath;
    }

    public void setAttachmentPath(String attachmentPath) {
        this.attachmentPath = attachmentPath;
    }

    public String getAttachmentIsDel() {
        return attachmentIsDel;
    }

    public void setAttachmentIsDel(String attachmentIsDel) {
        this.attachmentIsDel = attachmentIsDel;
    }
}
